<!--
 * @Description: 
 * @Author: Chen bi
 * @Date: 2022-09-18 16:23:50
 * @LastEditTime: 2022-09-18 16:25:34
 * @LastEditors: Chen bi
-->
<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8">
    <title></title>
    <script src="../js/vue.js"></script>
</head>

<body>

    <div id="app">
        <input type="text" v-model.number="data" />
        <p>{{ data | trimPlusMax }}</p>
    </div>

    <script>
        var app = new Vue({
            el: "#app",
            data: {
                data: ''
            },
            filters: {
                trimPlusMax(value) {
                    return value.split(' ').join('')
                }
            }

        })
    </script>
</body>

</html>